<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2018/7/24
 * Time: 16:36
 */

$content = date("Ymd H:i:s") . PHP_EOL;
$result = swoole_async_writefile(__DIR__ . "/1.log", $content, function ($filename) {
    echo "成功" . PHP_EOL;
}, FILE_APPEND); //FILE_APPEND追加的方式写入
var_dump($result);

echo "start" . PHP_EOL;